package com.jiazhong.ditest;

import org.junit.jupiter.api.Test;
import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

/**
 * @Auther:shuXin
 */
public class TestDeptEmp {
    @Test
    public void test01(){
        /*ApplicationContext ac = new ClassPathXmlApplicationContext("bean-ditest.xml");
        Emp emp = ac.getBean("emp2",Emp.class);
        System.out.println(emp);
        emp.work();*/

        ApplicationContext ac = new ClassPathXmlApplicationContext("bean-dilist.xml");
        Dept dept = (Dept) ac.getBean("dept");
        System.out.println(dept);
        dept.info();
    }
}
